﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Dubbo.Rpc
{
    public interface IFilter
    {
        /**
	     * do invoke filter.
	     * 
	     * <code>
	     * // before filter
         * Result result = invoker.invoke(invocation);
         * // after filter
         * return result;
         * </code>
         * 
         * @see com.alibaba.dubbo.rpc.Invoker#invoke(Invocation)
	     * @param invoker service
	     * @param invocation invocation.
	     * @return invoke result.
	     * @throws RpcException
	     */
        IResult Invoke<T>(IInvoker<T> invoker, IInvocation<T> invocation);
    }
}
